<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE topic
  PUBLIC "-//OASIS//DTD DITA Composite//EN" "ditabase.dtd">
<topic xml:lang="en" id="topic1">
  <title>pg_foreign_server</title>
  <body>
    <p>The system catalog table <codeph>pg_foreign_server</codeph> stores foreign server definitions. A foreign server describes a source of external data, such as a remote server. You access a foreign server via a foreign-data wrapper.</p>
    <table id="table_zgy_xfx_tz">
      <title>pg_catalog.pg_foreign_server</title>
      <tgroup cols="4">
        <colspec colnum="1" colname="col1" colwidth="131pt"/>
        <colspec colnum="2" colname="col2" colwidth="86pt"/>
        <colspec colnum="3" colname="col3" colwidth="85pt"/>
        <colspec colnum="4" colname="col4" colwidth="147pt"/>
        <thead>
          <row>
            <entry colname="col1">column</entry>
            <entry colname="col2">type</entry>
            <entry colname="col3">references</entry>
            <entry colname="col4">description</entry>
          </row>
        </thead>
        <tbody>
          <row>
            <entry colname="col1"><codeph>srvname</codeph></entry>
            <entry colname="col2">name</entry>
            <entry colname="col3"/>
            <entry colname="col4">Name of the foreign server.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>srvowner</codeph></entry>
            <entry colname="col2">oid</entry>
            <entry colname="col3">pg_authid.oid</entry>
            <entry colname="col4">Owner of the foreign server.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>srvfdw</codeph></entry>
            <entry colname="col2">oid</entry>
            <entry colname="col3">pg_foreign_data_wrapper.oid</entry>
            <entry colname="col4">OID of the foreign-data wrapper of this foreign server.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>srvtype</codeph></entry>
            <entry colname="col2">text</entry>
            <entry colname="col3"></entry>
            <entry colname="col4">Type of server (optional).</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>srvversion</codeph></entry>
            <entry colname="col2">text</entry>
            <entry colname="col3"></entry>
            <entry colname="col4">Version of the server (optional).</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>srvacl</codeph></entry>
            <entry colname="col2">aclitem[]</entry>
            <entry colname="col3"></entry>
            <entry colname="col4">Access privileges; see <codeph><xref href="../sql_commands/GRANT.xml#topic1" type="topic" format="dita"/></codeph> and <codeph><xref href="../sql_commands/REVOKE.xml#topic1" type="topic" format="dita"/></codeph> for details.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>srvoptions</codeph></entry>
            <entry colname="col2">text[]</entry>
            <entry colname="col3"></entry>
            <entry colname="col4">Foreign server-specific options, as "keyword=value" strings.</entry>
          </row>
        </tbody>
      </tgroup>
    </table>
  </body>
</topic>
